package com.example.web.bean;

import java.util.List;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

import lombok.Data;
@Data
@ConfigurationProperties(prefix = "spring.datasource.db2")
public class ShardDataSource2 {
	@Value("${spring.datasource.db2.driverClassName}")
    private String driverClassName;
	@Value("${spring.datasource.db2.url}")
    private String url;
	@Value("${spring.datasource.db2.username}")
	private String username;
	@Value("${spring.datasource.db2.password}")
    private String password;
	@Value("${spring.datasource.db2.filters}")
    private String filters;
	@Value("${spring.datasource.db2.maxActive}")
    private int maxActive;
	@Value("${spring.datasource.db2.initialSize}")
    private int initialSize;
	@Value("${spring.datasource.db2.maxWait}")
    private int maxWait;
	@Value("${spring.datasource.db2.minIdle}")
    private int minIdle;
	@Value("${spring.datasource.db2.timeBetweenEvictionRunsMillis}")
    private int timeBetweenEvictionRunsMillis;
	@Value("${spring.datasource.db2.minEvictableIdleTimeMillis}")
    private int minEvictableIdleTimeMillis;
	@Value("${spring.datasource.db2.validationQuery}")
    private String validationQuery;
	@Value("${spring.datasource.db2.testWhileIdle}")
    private boolean testWhileIdle;
	@Value("${spring.datasource.db2.testOnBorrow}")
    private boolean testOnBorrow;
	@Value("${spring.datasource.db2.testOnReturn}")
    private boolean testOnReturn;
	@Value("${spring.datasource.db2.poolPreparedStatements}")
    private boolean poolPreparedStatements;
	@Value("${spring.datasource.db2.maxPoolPreparedStatementPerConnectionSize}")
    private int maxPoolPreparedStatementPerConnectionSize;
	@Value("${spring.datasource.db2.removeAbandoned}")
	private boolean removeAbandoned;
	@Value("${spring.datasource.db2.removeAbandonedTimeout}")
    private int removeAbandonedTimeout;
	@Value("${spring.datasource.db2.logAbandoned}")
    private boolean logAbandoned;
	@Value("${spring.datasource.db2.connectionInitSqls}")
    private List<String> connectionInitSqls;
	@Value("${spring.datasource.db2.connectionProperties}")
    private String connectionProperties;
}
